/*
* @author dumeng
*/
'use strict'
import { imgFooterComp, navigationOne, navigationTwo } from '../widget'
import {
  Color,
  Input, Radio,
  Select,
  Slider,
  UploadImage
} from '@/components/CustomPage/fields/widget'
import { DataOption } from '@/components/CustomPage/apps/map/dataops'
import { imgOption } from './imgops'
import { DataOption4Img } from './dataops4img'
import { BasicOption } from '@/components/CustomPage/apps/map/basicops'
export default {
  /**
   * 导航组件-顶部导航样式1
   */
  navigationOne() {
    return {
      target: navigationOne,
      parameter: {
        relate: false,
        mold: 'field',
        label: '顶部导航样式1',
        value: []
      },
      option: [
        {
          title: '基础配置', fields: [
            ...BasicOption(),
            {
              type: Radio,
              option: {
                label: '是否固定定位',
                name: 'isFixed',
                list: [
                  { name: '是', value: '1' },
                  { name: '否', value: '2' }
                ],
                value: '2'
              }
            },
            {
              type: Slider,
              option: {
                label: '导航高度',
                name: 'height',
                value: 88,
                max: 200,
                step: 1
              }
            },

            {
              type: Color,
              option: {
                label: '背景颜色',
                name: 'bgcolor',
                value: '#fff',
                showalpha: true
              }
            },
            {
              type: Color,
              option: {
                label: '文字颜色',
                name: 'textcolor',
                value: '#333',
                showalpha: true
              }
            },
            {
              type: Color,
              option: {
                label: '选中颜色',
                name: 'currentcolor',
                value: '',
                showalpha: true
              }
            },
            { type: UploadImage, option: { label: '背景图', name: 'bgImage' }},
            {
              type: Slider,
              option: {
                label: '背景图高度',
                name: 'bgHeight',
                value: 260,
                max: 500,
                step: 1
              }
            }

          ]
        },
        /* {
          type: Extend,
          option: {
            label: '数据配置',
            name: 'list',
            initalize: true,
            fields: [
              { type: Input, option: { label: '导航名称', name: 'label', required: true }},
              { type: Link, option: { label: '链接地址', name: 'link' }},
              {
                type: Switch,
                option: {
                  label: '是否显示',
                  name: 'isShow',
                  value: true,
                  activetext: '显示',
                  inactivetext: '不显示'
                }
              }, {
                type: Switch,
                option: {
                  label: '是否需要登录',
                  name: 'isShow',
                  value: true,
                  activetext: '需要',
                  inactivetext: '不需要'
                }
              }
            ]
          }
        },*/
        ...DataOption4Img('navigationOne', [], 'text')
      ]
    }
  },
  /**
   * 导航组件-顶部导航样式2
   */
  navigationTwo() {
    return {
      target: navigationTwo,
      parameter: {
        relate: false,
        mold: 'field',
        label: '顶部导航样式2',
        value: []
      },
      option: [
        {
          title: '基础配置', fields: [
            ...BasicOption(),
            {
              type: Radio,
              option: {
                label: '是否固定定位',
                name: 'isFixed',
                list: [
                  { name: '是', value: '1' },
                  { name: '否', value: '2' }
                ],
                value: '2'
              }
            },
            {
              type: Slider,
              option: {
                label: '导航高度',
                name: 'height',
                value: 88,
                max: 200,
                step: 1
              }
            },
            {
              type: Color,
              option: {
                label: '背景颜色',
                name: 'bgcolor',
                value: '#fff',
                showalpha: true
              }
            },
            {
              type: Color,
              option: {
                label: '文字颜色',
                name: 'textcolor',
                value: '#333',
                showalpha: true
              }
            },
            {
              type: Color,
              option: {
                label: '选中颜色',
                name: 'currentcolor',
                value: '',
                showalpha: true
              }
            }
          ]
        },
        /* {
          type: Extend,
          option: {
            label: '数据配置',
            name: 'list',
            initalize: true,
            fields: [
              { type: Input, option: { label: '导航名称', name: 'label', required: true }},
              { type: Link, option: { label: '链接地址', name: 'link' }},
              {
                type: Switch,
                option: {
                  label: '是否显示',
                  name: 'isShow',
                  value: true,
                  activetext: '显示',
                  inactivetext: '不显示'
                }
              }, {
                type: Switch,
                option: {
                  label: '是否需要登录',
                  name: 'isShow',
                  value: true,
                  activetext: '需要',
                  inactivetext: '不需要'
                }
              }
            ]
          }
        },*/
        ...DataOption4Img('navigationTwo', [], 'text')
      ]
    }
  }
}
